
#设置证书互信
ssh-keygen
ssh-copy-id root@k8s-node-1

scp -P 1022 -r root@k8s-master-1:/opt/kubernetes/ /opt/
rm -f /opt/kubernetes/bin/kube-apiserver
rm -f /opt/kubernetes/bin/kube-scheduler 
rm -f /opt/kubernetes/bin/kube-controller-manager

rm -rf /opt/kubernetes/cfg
rm -rf /opt/kubernetes/yaml

mkdir -p /opt/kubernetes/cfg






scp -P 1022 -r root@k8s-master-1:/opt/kubernetes/ /opt/

scp -P 1022 -r root@k8s-master-1:/etc/kubernetes/ /etc/

scp -P 1022 -r root@k8s-master-1:/root/.kube/ /root/

scp -P 22 -r /opt/kubernetes/ root@k8s-node-1:/opt/
scp -P 22 -r /etc/kubernetes/ root@k8s-node-1:/etc/
scp -P 22 -r /root/.kube/ root@k8s-node-1:/root/